Page({
  data: {
    userInfo: {},
    // 收藏的数量
    collectNumber: 0
  },
  onShow() {
    const userInfo = wx.getStorageSync("userInfo")
    const collect = wx.getStorageSync("collect") || []
    this.setData({
      userInfo,
      collectNumber: collect.length
    })
  }
})